public class Problem28 {
	public static void main(String[] args) {
		int size = 1001;
		int d = 2;
		int sum = 1;
		int cur = 1;
		for (int i = 3; i <= size; i += 2) {
			for (int j = 0; j < 4; j++) {
				cur += d;
				sum += cur;
			}
			d += 2;
		}

		System.out.println("" + sum);
	}
}
